'use strict';

const jwt = require('jsonwebtoken');
const secret = 'gp27';

exports.creatToken = payload => {
  return jwt.sign(payload, secret);
};

exports.parseToken = token => {
  return jwt.verify(token, secret);
};
